package com.iris.live.services.data.repositories;

import com.iris.live.services.data.models.MarketAnnualBudgetModel;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;

/**
 * Created by HangLiu on 2017/9/27.
 */
public interface MarketAnnualBudgetRepository extends JpaRepository<MarketAnnualBudgetModel, Integer>, JpaSpecificationExecutor<MarketAnnualBudgetModel> {
    @Query("select a from MarketAnnualBudgetModel a where a.permit=?1 and a.statDate=?2")
    MarketAnnualBudgetModel findModelByPermitAndYear( String permit,String year);
}
